package com.meng.controller;

import javax.servlet.http.HttpServletRequest;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.meng.anno.AuthAccess;

/**
 * Controller级拦截，在URL后增加?token=controller参数
 * 
 * @author fanling.meng
 *
 */
@Controller
@RequestMapping("/auth")
@AuthAccess(authValue = "controller")
public class AuthController {

	private static final Logger logger = LoggerFactory
			.getLogger(AuthController.class);

	@RequestMapping(value = "/auth")
	public String auth(HttpServletRequest request) {
		logger.info("auth  访问成功");
		return "home";
	}

}
